package com.ehotting.mqbd.core.config;

import com.ehotting.mqbd.api.bean.solver.ModuleSolverBean;
import com.ehotting.mqbd.api.bean.solver.ModuleInfoBean;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Primary;
import org.springframework.stereotype.Component;
import java.util.List;

@Configuration
@RefreshScope
@Component
@ConfigurationProperties(prefix = "mqbd")
@Primary
public class MqbdCoreServerInfoConfig {

    private ModuleSolverBean solver;

    private List<ModuleInfoBean>  modules;

    public ModuleSolverBean getSolver() {
        return solver;
    }

    public void setSolver(ModuleSolverBean solver) {
        this.solver = solver;
    }

    public List<ModuleInfoBean> getModules() {
        return modules;
    }

    public void setModules(List<ModuleInfoBean> modules) {
        this.modules = modules;
    }
}
